import request from '@/utils/request'

const api = {
    applianceList: '/appliance/lists',
    applianceAdd: '/appliance/add',
    applianceEdit: '/appliance/edit',
    appliancePutaway: '/appliance/putaway',
    applianceDownfall: '/appliance/downfall',
    applianceDelete: '/appliance/delete',
    appliancePriceList: '/appliancePrice/lists',
    appliancePriceAdd: '/appliancePrice/add',
    appliancePriceEdit: '/appliancePrice/edit',
    appliancePriceDel: '/appliancePrice/delete',
    applianceOrder: '/applianceOrder/lists',
    applianceOrderDetail: '/applianceOrder/detail',
    applianceStoreList: '/applianceStore/lists',
    applianceOrderPush: '/applianceStore/orderPush'
}

export function applianceOrderPush (parameter) {
  return request({
      url: api.applianceOrderPush,
      method: 'get',
      params: parameter
  })
}

export function applianceStoreList (parameter) {
    return request({
        url: api.applianceStoreList,
        method: 'get',
        params: parameter
    })
  }

export function applianceOrderDetail (parameter) {
    return request({
        url: api.applianceOrderDetail,
        method: 'get',
        params: parameter
    })
  }

export function applianceOrder (parameter) {
    return request({
        url: api.applianceOrder,
        method: 'get',
        params: parameter
    })
}

export function appliancePriceDel (parameter) {
    return request({
        url: api.appliancePriceDel,
        method: 'get',
        params: parameter
    })
}

export function appliancePriceEdit (parameter) {
    return request({
        url: api.appliancePriceEdit,
        method: 'post',
        data: parameter
    })
}

export function appliancePriceAdd (parameter) {
    return request({
        url: api.appliancePriceAdd,
        method: 'post',
        data: parameter
    })
}

export function appliancePriceList (parameter) {
    return request({
        url: api.appliancePriceList,
        method: 'get',
        params: parameter
    })
}

export function applianceDel (parameter) {
    return request({
        url: api.applianceDelete,
        method: 'get',
        params: parameter
    })
}

export function appliancePutaway (parameter) {
    return request({
        url: api.appliancePutaway,
        method: 'post',
        data: parameter
    })
}

export function applianceDownfall (parameter) {
    return request({
        url: api.applianceDownfall,
        method: 'post',
        data: parameter
    })
}

export function applianceEdit (parameter) {
    return request({
        url: api.applianceEdit,
        method: 'post',
        data: parameter
    })
}

export function applianceAdd (parameter) {
    return request({
        url: api.applianceAdd,
        method: 'post',
        data: parameter
    })
}

export function applianceList (parameter) {
    return request({
        url: api.applianceList,
        method: 'get',
        params: parameter
    })
}
